\(\int \frac {\sin ^3(c+d x)}{(a-a \sin ^2(c+d x))^2} \, dx\) [51]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [B] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 24, antiderivative size = 33 \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=-\frac {\sec (c+d x)}{a^2 d}+\frac {\sec ^3(c+d x)}{3 a^2 d} \]

[Out]

-sec(d*x+c)/a^2/d+1/3*sec(d*x+c)^3/a^2/d

Rubi [A] (verified)

Time = 0.04 (sec) , antiderivative size = 33, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.083, Rules used = {3254, 2686} \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=\frac {\sec ^3(c+d x)}{3 a^2 d}-\frac {\sec (c+d x)}{a^2 d} \]

[In]

Int[Sin[c + d*x]^3/(a - a*Sin[c + d*x]^2)^2,x]

[Out]

-(Sec[c + d*x]/(a^2*d)) + Sec[c + d*x]^3/(3*a^2*d)

Rule 2686

Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_Symbol] :> Dist[a/f, Subst[
Int[(a*x)^(m - 1)*(-1 + x^2)^((n - 1)/2), x], x, Sec[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n -
1)/2] &&  !(IntegerQ[m/2] && LtQ[0, m, n + 1])

Rule 3254

Int[(u_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]^2)^(p_), x_Symbol] :> Dist[a^p, Int[ActivateTrig[u*cos[e + f*x
]^(2*p)], x], x] /; FreeQ[{a, b, e, f, p}, x] && EqQ[a + b, 0] && IntegerQ[p]

Rubi steps \begin{align*} \text {integral}& = \frac {\int \sec (c+d x) \tan ^3(c+d x) \, dx}{a^2} \\ & = \frac {\text {Subst}\left (\int \left (-1+x^2\right ) \, dx,x,\sec (c+d x)\right )}{a^2 d} \\ & = -\frac {\sec (c+d x)}{a^2 d}+\frac {\sec ^3(c+d x)}{3 a^2 d} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.07 (sec) , antiderivative size = 31, normalized size of antiderivative = 0.94 \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=\frac {-\frac {\sec (c+d x)}{d}+\frac {\sec ^3(c+d x)}{3 d}}{a^2} \]

[In]

Integrate[Sin[c + d*x]^3/(a - a*Sin[c + d*x]^2)^2,x]

[Out]

(-(Sec[c + d*x]/d) + Sec[c + d*x]^3/(3*d))/a^2

Maple [A] (verified)

Time = 0.54 (sec) , antiderivative size = 29, normalized size of antiderivative = 0.88

method result size
derivativedivides \(\frac {\frac {1}{3 \cos \left (d x +c \right )^{3}}-\frac {1}{\cos \left (d x +c \right )}}{d \,a^{2}}\) \(29\)
default \(\frac {\frac {1}{3 \cos \left (d x +c \right )^{3}}-\frac {1}{\cos \left (d x +c \right )}}{d \,a^{2}}\) \(29\)
risch \(-\frac {2 \left (3 \,{\mathrm e}^{5 i \left (d x +c \right )}+2 \,{\mathrm e}^{3 i \left (d x +c \right )}+3 \,{\mathrm e}^{i \left (d x +c \right )}\right )}{3 d \,a^{2} \left ({\mathrm e}^{2 i \left (d x +c \right )}+1\right )^{3}}\) \(56\)
parallelrisch \(\frac {-2-6 \cos \left (2 d x +2 c \right )-6 \cos \left (d x +c \right )-2 \cos \left (3 d x +3 c \right )}{3 a^{2} d \left (\cos \left (3 d x +3 c \right )+3 \cos \left (d x +c \right )\right )}\) \(61\)
norman \(\frac {-\frac {8 \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d a}-\frac {32 \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d a}+\frac {4}{3 a d}-\frac {4 \left (\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d a}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{3} a \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )-1\right )^{3}}\) \(101\)

[In]

int(sin(d*x+c)^3/(a-a*sin(d*x+c)^2)^2,x,method=_RETURNVERBOSE)

[Out]

1/d/a^2*(1/3/cos(d*x+c)^3-1/cos(d*x+c))

Fricas [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 28, normalized size of antiderivative = 0.85 \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=-\frac {3 \, \cos \left (d x + c\right )^{2} - 1}{3 \, a^{2} d \cos \left (d x + c\right )^{3}} \]

[In]

integrate(sin(d*x+c)^3/(a-a*sin(d*x+c)^2)^2,x, algorithm="fricas")

[Out]

-1/3*(3*cos(d*x + c)^2 - 1)/(a^2*d*cos(d*x + c)^3)

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 156 vs. \(2 (26) = 52\).

Time = 3.92 (sec) , antiderivative size = 156, normalized size of antiderivative = 4.73 \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=\begin {cases} - \frac {12 \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )}}{3 a^{2} d \tan ^{6}{\left (\frac {c}{2} + \frac {d x}{2} \right )} - 9 a^{2} d \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 9 a^{2} d \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )} - 3 a^{2} d} + \frac {4}{3 a^{2} d \tan ^{6}{\left (\frac {c}{2} + \frac {d x}{2} \right )} - 9 a^{2} d \tan ^{4}{\left (\frac {c}{2} + \frac {d x}{2} \right )} + 9 a^{2} d \tan ^{2}{\left (\frac {c}{2} + \frac {d x}{2} \right )} - 3 a^{2} d} & \text {for}\: d \neq 0 \\\frac {x \sin ^{3}{\left (c \right )}}{\left (- a \sin ^{2}{\left (c \right )} + a\right )^{2}} & \text {otherwise} \end {cases} \]

[In]

integrate(sin(d*x+c)**3/(a-a*sin(d*x+c)**2)**2,x)

[Out]

Piecewise((-12*tan(c/2 + d*x/2)**2/(3*a**2*d*tan(c/2 + d*x/2)**6 - 9*a**2*d*tan(c/2 + d*x/2)**4 + 9*a**2*d*tan
(c/2 + d*x/2)**2 - 3*a**2*d) + 4/(3*a**2*d*tan(c/2 + d*x/2)**6 - 9*a**2*d*tan(c/2 + d*x/2)**4 + 9*a**2*d*tan(c
/2 + d*x/2)**2 - 3*a**2*d), Ne(d, 0)), (x*sin(c)**3/(-a*sin(c)**2 + a)**2, True))

Maxima [A] (verification not implemented)

none

Time = 0.28 (sec) , antiderivative size = 28, normalized size of antiderivative = 0.85 \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=-\frac {3 \, \cos \left (d x + c\right )^{2} - 1}{3 \, a^{2} d \cos \left (d x + c\right )^{3}} \]

[In]

integrate(sin(d*x+c)^3/(a-a*sin(d*x+c)^2)^2,x, algorithm="maxima")

[Out]

-1/3*(3*cos(d*x + c)^2 - 1)/(a^2*d*cos(d*x + c)^3)

Giac [A] (verification not implemented)

none

Time = 0.33 (sec) , antiderivative size = 28, normalized size of antiderivative = 0.85 \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=-\frac {3 \, \cos \left (d x + c\right )^{2} - 1}{3 \, a^{2} d \cos \left (d x + c\right )^{3}} \]

[In]

integrate(sin(d*x+c)^3/(a-a*sin(d*x+c)^2)^2,x, algorithm="giac")

[Out]

-1/3*(3*cos(d*x + c)^2 - 1)/(a^2*d*cos(d*x + c)^3)

Mupad [B] (verification not implemented)

Time = 0.05 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.79 \[ \int \frac {\sin ^3(c+d x)}{\left (a-a \sin ^2(c+d x)\right )^2} \, dx=-\frac {{\cos \left (c+d\,x\right )}^2-\frac {1}{3}}{a^2\,d\,{\cos \left (c+d\,x\right )}^3} \]

[In]

int(sin(c + d*x)^3/(a - a*sin(c + d*x)^2)^2,x)

[Out]

-(cos(c + d*x)^2 - 1/3)/(a^2*d*cos(c + d*x)^3)